package com.lbtc.service;

import com.github.pagehelper.PageInfo;
import com.google.zxing.WriterException;
import com.lbtc.exception.LbtcMallException;
import com.lbtc.request.CreateOrderReq;
import com.lbtc.vo.OrderVO;
import org.springframework.transaction.annotation.Transactional;

public interface OrderService {

    @Transactional(rollbackFor = Exception.class)
    String create(CreateOrderReq createOrderReq) throws LbtcMallException;

    OrderVO detail(String orderNo) throws LbtcMallException;

    PageInfo listForCustomer(Integer pageNum, Integer pageSize) throws LbtcMallException;

    void cancel(String orderNum) throws LbtcMallException;

    String qrcode(String orderNo) throws WriterException;

    void pay(String orderNo) throws LbtcMallException;

    PageInfo listForAdmin(Integer pageNum, Integer pageSize) throws LbtcMallException;

    void deliver(String orderNo) throws LbtcMallException;

    void finish(String orderNo) throws LbtcMallException;
}
